Attach packages

library(tidyverse)
library(DT)
library(plotly)

Create interactive graph with iris data and plotly

iris_graph <- ggplot(iris,
                     aes(x = Petal.Width,
                         y = Petal.Length)) +
  geom_point(aes(size = Sepal.Width, color = Species)) +
  labs(x = "Petal Width (cm)",
       y = "Petal Length (cm)")


ggplotly(iris_graph)

Make interactive table using DT and msleep data

datatable(msleep)